package com.bootdo.hotel.dao;

import com.bootdo.hotel.domain.HotelRoom;

import java.util.List;
import java.util.Map;

import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

/**
 * 
 * @author haojiangbo
 * @email 2100272728@qq.com
 * @date 2019-10-18 11:10:02
 */
@Mapper
public interface HotelRoomDao {

	HotelRoom get(Long id);

	@Select("select * from me_hotel_room where hotel_id = #{hotelId} and  name = #{name} limit 1")
	HotelRoom getHotelIdAndName(@Param("hotelId") Long hotelId,@Param("name") String name);
	
	List<HotelRoom> list(Map<String,Object> map);
	
	int count(Map<String,Object> map);
	
	int save(HotelRoom hotelRoom);
	
	int update(HotelRoom hotelRoom);
	
	int remove(Long id);
	
	int batchRemove(Long[] ids);
}
